import http from '@/utils/http'

export const baseUrl = process.env.VUE_APP_BASE_API;

export const fileUrl = process.env.VUE_APP_FILE_URL;

// 获取枚举类型
export const getEnums = () => {
	return http.get('/enums');
};

// 登录
export const login = (params) => {
	return http.get('g?service=nurseperson&operation=login', params);
};

// 获取短信验证码
export const getCode = (type, params) => {
	return http.get(`/g?service=doctorperson&operation=${type}`, params);
}

// 验证码校验
export const checkCode = (params) => {
	return http.get('/p?service=doctorperson&operation=verifypasswdcode', params);
}

// 注册新用户
export const register = (params) => {
	return http.get('/p?service=nurseperson&operation=regist', params);
}

// 重置密码
export const resetPassword = (params) => {
	return http.get('/g?service=nurseperson&operation=resetpasswd', params);
}

// 密码变更
export const editPassword = (params) => {
	return http.get('/p?service=nurseperson&operation=editpasswd', params);
}

// 获取抢单须知说明
export const getPickbook = () => {
	return http.get('/g?service=pzwap&operation=pickbook');
}
